package com.sh.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("resfood")
public class Resfood implements Serializable, Commodity {

    @TableId(type = IdType.AUTO)
    private Integer fid;
    private String fname;
    private Double normprice;
    @TableField(value = "realprice")
    private Double realprice;
    private String detail;
    private String fphoto;

    @TableField(exist = false)
    private long detailCount;  // 菜品查看数

    @Override
    public Double getRealprice() {
        return realprice;
    }



//    private Long praise;
}
